3.2.2 \(\int \frac {\sin ^4(c+d x)}{(a+a \sec (c+d x))^3} \, dx\) [102]

Optimal. Leaf size=108 \[ \frac {51 x}{8 a^3}-\frac {7 \sin (c+d x)}{a^3 d}+\frac {19 \cos (c+d x) \sin (c+d x)}{8 a^3 d}+\frac {\cos ^3(c+d x) \sin (c+d x)}{4 a^3 d}-\frac {4 \sin (c+d x)}{a^3 d (1+\cos (c+d x))}+\frac {\sin ^3(c+d x)}{a^3 d} \]

[Out]

51/8*x/a^3-7*sin(d*x+c)/a^3/d+19/8*cos(d*x+c)*sin(d*x+c)/a^3/d+1/4*cos(d*x+c)^3*sin(d*x+c)/a^3/d-4*sin(d*x+c)/
a^3/d/(1+cos(d*x+c))+sin(d*x+c)^3/a^3/d

________________________________________________________________________________________

Rubi [A]
time = 0.23, antiderivative size = 108, normalized size of antiderivative = 1.00, number of steps used = 13, number of rules used = 8, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.381, Rules used = {3957, 2954, 2951, 2727, 2717, 2715, 8, 2713} \begin {gather*} \frac {\sin ^3(c+d x)}{a^3 d}-\frac {7 \sin (c+d x)}{a^3 d}+\frac {\sin (c+d x) \cos ^3(c+d x)}{4 a^3 d}+\frac {19 \sin (c+d x) \cos (c+d x)}{8 a^3 d}-\frac {4 \sin (c+d x)}{a^3 d (\cos (c+d x)+1)}+\frac {51 x}{8 a^3} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Sin[c + d*x]^4/(a + a*Sec[c + d*x])^3,x]

[Out]

(51*x)/(8*a^3) - (7*Sin[c + d*x])/(a^3*d) + (19*Cos[c + d*x]*Sin[c + d*x])/(8*a^3*d) + (Cos[c + d*x]^3*Sin[c +
 d*x])/(4*a^3*d) - (4*Sin[c + d*x])/(a^3*d*(1 + Cos[c + d*x])) + Sin[c + d*x]^3/(a^3*d)

Rule 8

Int[a_, x_Symbol] :> Simp[a*x, x] /; FreeQ[a, x]

Rule 2713

Int[sin[(c_.) + (d_.)*(x_)]^(n_), x_Symbol] :> Dist[-d^(-1), Subst[Int[Expand[(1 - x^2)^((n - 1)/2), x], x], x
, Cos[c + d*x]], x] /; FreeQ[{c, d}, x] && IGtQ[(n - 1)/2, 0]

Rule 2715

Int[((b_.)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(-b)*Cos[c + d*x]*((b*Sin[c + d*x])^(n - 1)/(d*n))
, x] + Dist[b^2*((n - 1)/n), Int[(b*Sin[c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1] && Integ
erQ[2*n]

Rule 2717

Int[sin[Pi/2 + (c_.) + (d_.)*(x_)], x_Symbol] :> Simp[Sin[c + d*x]/d, x] /; FreeQ[{c, d}, x]

Rule 2727

Int[((a_) + (b_.)*sin[(c_.) + (d_.)*(x_)])^(-1), x_Symbol] :> Simp[-Cos[c + d*x]/(d*(b + a*Sin[c + d*x])), x]
/; FreeQ[{a, b, c, d}, x] && EqQ[a^2 - b^2, 0]

Rule 2951

Int[cos[(e_.) + (f_.)*(x_)]^(p_)*((d_.)*sin[(e_.) + (f_.)*(x_)])^(n_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(
m_), x_Symbol] :> Dist[1/a^p, Int[ExpandTrig[(d*sin[e + f*x])^n*(a - b*sin[e + f*x])^(p/2)*(a + b*sin[e + f*x]
)^(m + p/2), x], x], x] /; FreeQ[{a, b, d, e, f}, x] && EqQ[a^2 - b^2, 0] && IntegersQ[m, n, p/2] && ((GtQ[m,
0] && GtQ[p, 0] && LtQ[-m - p, n, -1]) || (GtQ[m, 2] && LtQ[p, 0] && GtQ[m + p/2, 0]))

Rule 2954

Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((d_.)*sin[(e_.) + (f_.)*(x_)])^(n_)*((a_) + (b_.)*sin[(e_.) + (f_.)*
(x_)])^(m_), x_Symbol] :> Dist[(a/g)^(2*m), Int[(g*Cos[e + f*x])^(2*m + p)*((d*Sin[e + f*x])^n/(a - b*Sin[e +
f*x])^m), x], x] /; FreeQ[{a, b, d, e, f, g, n, p}, x] && EqQ[a^2 - b^2, 0] && ILtQ[m, 0]

Rule 3957

Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_.), x_Symbol] :> Int[(g*Co
s[e + f*x])^p*((b + a*Sin[e + f*x])^m/Sin[e + f*x]^m), x] /; FreeQ[{a, b, e, f, g, p}, x] && IntegerQ[m]

Rubi steps

\begin {align*} \int \frac {\sin ^4(c+d x)}{(a+a \sec (c+d x))^3} \, dx &=-\int \frac {\cos ^3(c+d x) \sin ^4(c+d x)}{(-a-a \cos (c+d x))^3} \, dx\\ &=-\frac {\int \cos (c+d x) (-a+a \cos (c+d x))^3 \cot ^2(c+d x) \, dx}{a^6}\\ &=\frac {\int \left (4 a+\frac {4 a}{-1-\cos (c+d x)}-4 a \cos (c+d x)+4 a \cos ^2(c+d x)-3 a \cos ^3(c+d x)+a \cos ^4(c+d x)\right ) \, dx}{a^4}\\ &=\frac {4 x}{a^3}+\frac {\int \cos ^4(c+d x) \, dx}{a^3}-\frac {3 \int \cos ^3(c+d x) \, dx}{a^3}+\frac {4 \int \frac {1}{-1-\cos (c+d x)} \, dx}{a^3}-\frac {4 \int \cos (c+d x) \, dx}{a^3}+\frac {4 \int \cos ^2(c+d x) \, dx}{a^3}\\ &=\frac {4 x}{a^3}-\frac {4 \sin (c+d x)}{a^3 d}+\frac {2 \cos (c+d x) \sin (c+d x)}{a^3 d}+\frac {\cos ^3(c+d x) \sin (c+d x)}{4 a^3 d}-\frac {4 \sin (c+d x)}{a^3 d (1+\cos (c+d x))}+\frac {3 \int \cos ^2(c+d x) \, dx}{4 a^3}+\frac {2 \int 1 \, dx}{a^3}+\frac {3 \text {Subst}\left (\int \left (1-x^2\right ) \, dx,x,-\sin (c+d x)\right )}{a^3 d}\\ &=\frac {6 x}{a^3}-\frac {7 \sin (c+d x)}{a^3 d}+\frac {19 \cos (c+d x) \sin (c+d x)}{8 a^3 d}+\frac {\cos ^3(c+d x) \sin (c+d x)}{4 a^3 d}-\frac {4 \sin (c+d x)}{a^3 d (1+\cos (c+d x))}+\frac {\sin ^3(c+d x)}{a^3 d}+\frac {3 \int 1 \, dx}{8 a^3}\\ &=\frac {51 x}{8 a^3}-\frac {7 \sin (c+d x)}{a^3 d}+\frac {19 \cos (c+d x) \sin (c+d x)}{8 a^3 d}+\frac {\cos ^3(c+d x) \sin (c+d x)}{4 a^3 d}-\frac {4 \sin (c+d x)}{a^3 d (1+\cos (c+d x))}+\frac {\sin ^3(c+d x)}{a^3 d}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.48, size = 173, normalized size = 1.60 \begin {gather*} \frac {\sec \left (\frac {c}{2}\right ) \sec \left (\frac {1}{2} (c+d x)\right ) \left (2040 d x \cos \left (\frac {d x}{2}\right )+2040 d x \cos \left (c+\frac {d x}{2}\right )-3563 \sin \left (\frac {d x}{2}\right )-997 \sin \left (c+\frac {d x}{2}\right )-800 \sin \left (c+\frac {3 d x}{2}\right )-800 \sin \left (2 c+\frac {3 d x}{2}\right )+160 \sin \left (2 c+\frac {5 d x}{2}\right )+160 \sin \left (3 c+\frac {5 d x}{2}\right )-35 \sin \left (3 c+\frac {7 d x}{2}\right )-35 \sin \left (4 c+\frac {7 d x}{2}\right )+5 \sin \left (4 c+\frac {9 d x}{2}\right )+5 \sin \left (5 c+\frac {9 d x}{2}\right )\right )}{640 a^3 d} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Sin[c + d*x]^4/(a + a*Sec[c + d*x])^3,x]

[Out]

(Sec[c/2]*Sec[(c + d*x)/2]*(2040*d*x*Cos[(d*x)/2] + 2040*d*x*Cos[c + (d*x)/2] - 3563*Sin[(d*x)/2] - 997*Sin[c
+ (d*x)/2] - 800*Sin[c + (3*d*x)/2] - 800*Sin[2*c + (3*d*x)/2] + 160*Sin[2*c + (5*d*x)/2] + 160*Sin[3*c + (5*d
*x)/2] - 35*Sin[3*c + (7*d*x)/2] - 35*Sin[4*c + (7*d*x)/2] + 5*Sin[4*c + (9*d*x)/2] + 5*Sin[5*c + (9*d*x)/2]))
/(640*a^3*d)

________________________________________________________________________________________

Maple [A]
time = 0.14, size = 100, normalized size = 0.93

method result size
derivativedivides \(\frac {-4 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )+\frac {4 \left (-\frac {77 \left (\tan ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{16}-\frac {149 \left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{16}-\frac {123 \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{16}-\frac {35 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{16}\right )}{\left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )^{4}}+\frac {51 \arctan \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4}}{a^{3} d}\) \(100\)
default \(\frac {-4 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )+\frac {4 \left (-\frac {77 \left (\tan ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{16}-\frac {149 \left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{16}-\frac {123 \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{16}-\frac {35 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{16}\right )}{\left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )^{4}}+\frac {51 \arctan \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4}}{a^{3} d}\) \(100\)
risch \(\frac {51 x}{8 a^{3}}+\frac {25 i {\mathrm e}^{i \left (d x +c \right )}}{8 a^{3} d}-\frac {25 i {\mathrm e}^{-i \left (d x +c \right )}}{8 a^{3} d}-\frac {8 i}{a^{3} d \left ({\mathrm e}^{i \left (d x +c \right )}+1\right )}+\frac {\sin \left (4 d x +4 c \right )}{32 a^{3} d}-\frac {\sin \left (3 d x +3 c \right )}{4 a^{3} d}+\frac {5 \sin \left (2 d x +2 c \right )}{4 a^{3} d}\) \(117\)
norman \(\frac {\frac {51 x}{8 a}-\frac {51 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{4 a d}-\frac {187 \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4 a d}-\frac {245 \left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4 a d}-\frac {141 \left (\tan ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4 a d}-\frac {4 \left (\tan ^{9}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{a d}+\frac {51 x \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{2 a}+\frac {153 x \left (\tan ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4 a}+\frac {51 x \left (\tan ^{6}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{2 a}+\frac {51 x \left (\tan ^{8}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{8 a}}{\left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )^{4} a^{2}}\) \(188\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(d*x+c)^4/(a+a*sec(d*x+c))^3,x,method=_RETURNVERBOSE)

[Out]

4/d/a^3*(-tan(1/2*d*x+1/2*c)+(-77/16*tan(1/2*d*x+1/2*c)^7-149/16*tan(1/2*d*x+1/2*c)^5-123/16*tan(1/2*d*x+1/2*c
)^3-35/16*tan(1/2*d*x+1/2*c))/(1+tan(1/2*d*x+1/2*c)^2)^4+51/16*arctan(tan(1/2*d*x+1/2*c)))

________________________________________________________________________________________

Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 227 vs. \(2 (102) = 204\).
time = 0.49, size = 227, normalized size = 2.10 \begin {gather*} -\frac {\frac {\frac {35 \, \sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} + \frac {123 \, \sin \left (d x + c\right )^{3}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{3}} + \frac {149 \, \sin \left (d x + c\right )^{5}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{5}} + \frac {77 \, \sin \left (d x + c\right )^{7}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{7}}}{a^{3} + \frac {4 \, a^{3} \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} + \frac {6 \, a^{3} \sin \left (d x + c\right )^{4}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{4}} + \frac {4 \, a^{3} \sin \left (d x + c\right )^{6}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{6}} + \frac {a^{3} \sin \left (d x + c\right )^{8}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{8}}} - \frac {51 \, \arctan \left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1}\right )}{a^{3}} + \frac {16 \, \sin \left (d x + c\right )}{a^{3} {\left (\cos \left (d x + c\right ) + 1\right )}}}{4 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(d*x+c)^4/(a+a*sec(d*x+c))^3,x, algorithm="maxima")

[Out]

-1/4*((35*sin(d*x + c)/(cos(d*x + c) + 1) + 123*sin(d*x + c)^3/(cos(d*x + c) + 1)^3 + 149*sin(d*x + c)^5/(cos(
d*x + c) + 1)^5 + 77*sin(d*x + c)^7/(cos(d*x + c) + 1)^7)/(a^3 + 4*a^3*sin(d*x + c)^2/(cos(d*x + c) + 1)^2 + 6
*a^3*sin(d*x + c)^4/(cos(d*x + c) + 1)^4 + 4*a^3*sin(d*x + c)^6/(cos(d*x + c) + 1)^6 + a^3*sin(d*x + c)^8/(cos
(d*x + c) + 1)^8) - 51*arctan(sin(d*x + c)/(cos(d*x + c) + 1))/a^3 + 16*sin(d*x + c)/(a^3*(cos(d*x + c) + 1)))
/d

________________________________________________________________________________________

Fricas [A]
time = 3.09, size = 83, normalized size = 0.77 \begin {gather*} \frac {51 \, d x \cos \left (d x + c\right ) + 51 \, d x + {\left (2 \, \cos \left (d x + c\right )^{4} - 6 \, \cos \left (d x + c\right )^{3} + 11 \, \cos \left (d x + c\right )^{2} - 29 \, \cos \left (d x + c\right ) - 80\right )} \sin \left (d x + c\right )}{8 \, {\left (a^{3} d \cos \left (d x + c\right ) + a^{3} d\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(d*x+c)^4/(a+a*sec(d*x+c))^3,x, algorithm="fricas")

[Out]

1/8*(51*d*x*cos(d*x + c) + 51*d*x + (2*cos(d*x + c)^4 - 6*cos(d*x + c)^3 + 11*cos(d*x + c)^2 - 29*cos(d*x + c)
 - 80)*sin(d*x + c))/(a^3*d*cos(d*x + c) + a^3*d)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \frac {\int \frac {\sin ^{4}{\left (c + d x \right )}}{\sec ^{3}{\left (c + d x \right )} + 3 \sec ^{2}{\left (c + d x \right )} + 3 \sec {\left (c + d x \right )} + 1}\, dx}{a^{3}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(d*x+c)**4/(a+a*sec(d*x+c))**3,x)

[Out]

Integral(sin(c + d*x)**4/(sec(c + d*x)**3 + 3*sec(c + d*x)**2 + 3*sec(c + d*x) + 1), x)/a**3

________________________________________________________________________________________

Giac [A]
time = 0.52, size = 101, normalized size = 0.94 \begin {gather*} \frac {\frac {51 \, {\left (d x + c\right )}}{a^{3}} - \frac {32 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )}{a^{3}} - \frac {2 \, {\left (77 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{7} + 149 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 123 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 35 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )}}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 1\right )}^{4} a^{3}}}{8 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(d*x+c)^4/(a+a*sec(d*x+c))^3,x, algorithm="giac")

[Out]

1/8*(51*(d*x + c)/a^3 - 32*tan(1/2*d*x + 1/2*c)/a^3 - 2*(77*tan(1/2*d*x + 1/2*c)^7 + 149*tan(1/2*d*x + 1/2*c)^
5 + 123*tan(1/2*d*x + 1/2*c)^3 + 35*tan(1/2*d*x + 1/2*c))/((tan(1/2*d*x + 1/2*c)^2 + 1)^4*a^3))/d

________________________________________________________________________________________

Mupad [B]
time = 2.66, size = 98, normalized size = 0.91 \begin {gather*} \frac {51\,x}{8\,a^3}-\frac {4\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{a^3\,d}-\frac {\frac {77\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^7}{4}+\frac {149\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5}{4}+\frac {123\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3}{4}+\frac {35\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{4}}{a^3\,d\,{\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+1\right )}^4} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(c + d*x)^4/(a + a/cos(c + d*x))^3,x)

[Out]

(51*x)/(8*a^3) - (4*tan(c/2 + (d*x)/2))/(a^3*d) - ((35*tan(c/2 + (d*x)/2))/4 + (123*tan(c/2 + (d*x)/2)^3)/4 +
(149*tan(c/2 + (d*x)/2)^5)/4 + (77*tan(c/2 + (d*x)/2)^7)/4)/(a^3*d*(tan(c/2 + (d*x)/2)^2 + 1)^4)

________________________________________________________________________________________